package spark.network.protocol;

import spark.network.Util;

public class PreLoginResponseAck extends Response<PreLoginResponse> {
	public static final boolean RELIABLE_DEFAULT = false;
	public static final short TYPE = 0x07;
	private static final byte[] TYPE_BYTES = Util.makeBytes(TYPE);

	public PreLoginResponseAck() {
		super(RELIABLE_DEFAULT, TYPE_BYTES, PreLoginResponse.class);
	}

	public PreLoginResponseAck(PreLoginResponse query) {
		super(RELIABLE_DEFAULT, TYPE_BYTES, query, PreLoginResponse.class);
	}

	public static PreLoginResponseAck create(byte[] buffer, long receiveTime) {
		PreLoginResponseAck packet = new PreLoginResponseAck();
		packet.fill(buffer);
		packet.setTimeStampReceive(receiveTime);
		return packet;
	}
}